<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	template="/xhtml/bases/base.xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:c="http://java.sun.com/jsp/jstl/core"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:t="http://myfaces.apache.org/tomahawk"
	xmlns:bargas="http://barganhas.com.br/barganhas">
	
	<ui:define name="bodyNavigation">
		<h:panelGroup layout="block" styleClass="wrapperUserAccount">
			<h:panelGrid columns="2" columnClasses="userAccountColumn1, userAccountColumn2" style="width: 100%">
				<h:panelGroup layout="block" id="boxAccountProfileLeftSide">
					<h:graphicImage value="/images/anonymous_profile.png" styleClass="boxAccountProfileImage"
								rendered="#{appSessionBean.userAccount.profileImage eq null}"/>
					<h:graphicImage value="/fileserver?q=#{appSessionBean.userAccount.profileImage.id}" styleClass="boxAccountProfileImage"
								rendered="#{appSessionBean.userAccount.profileImage.id ne null}"/>
					
					<ul style="text-align: left;">
						<li><h:commandLink value="#{msg.myRegister}" action="#{userAccountBean.consult}" immediate="true" styleClass="menuOptionUserAccount"/></li>
						<li><h:commandLink value="#{msg.userAccountMyAdvertisements}" action="#{advertisementBean.list}" immediate="true" styleClass="menuOptionUserAccount"/></li>
					</ul>
				</h:panelGroup>
			
				<h:panelGroup layout="block">
					<!-- content header -->
					<h:panelGroup layout="block" styleClass="boxUserAccountForm boxUserAccountFormContext">
						<ui:insert name="accountHeader"/>
					</h:panelGroup>
					
					<!-- content -->
					<ui:insert name="userAccountContent"/>
					
					<!-- content bottom butons -->
					<h:panelGroup styleClass="boxUserAccountForm mainFormAccountUserBoxButtons" layout="block">
						<ui:insert name="accountBottomButtons"/>
					</h:panelGroup>
				</h:panelGroup>
			</h:panelGrid>
		</h:panelGroup>
		
		<t:saveState value="#{userAccountBean.userAccount}"/>
	</ui:define>
</ui:composition>
